/*     */ package eos.moe.dragoncore;
/*     */ 
/*     */ import blockbuster.utils.Interpolations;
/*     */ import eos.moe.dragoncore.api.model.AnimationEntityModel;
/*     */ import eos.moe.dragoncore.api.model.AnimationModelRenderer;
/*     */ import eos.moe.dragoncore.event.EventLoader;
/*     */ import java.io.ByteArrayInputStream;
/*     */ import java.io.IOException;
/*     */ import java.util.Map;
/*     */ import net.minecraft.client.Minecraft;
/*     */ import net.minecraft.client.entity.EntityOtherPlayerMP;
/*     */ import net.minecraft.client.model.ModelBase;
/*     */ import net.minecraft.client.model.ModelRenderer;
/*     */ import net.minecraft.client.renderer.ActiveRenderInfo;
/*     */ import net.minecraft.client.renderer.BufferBuilder;
/*     */ import net.minecraft.client.renderer.GlStateManager;
/*     */ import net.minecraft.client.renderer.OpenGlHelper;
/*     */ import net.minecraft.client.renderer.Tessellator;
/*     */ import net.minecraft.client.renderer.entity.RenderLivingBase;
/*     */ import net.minecraft.client.renderer.texture.ITickableTextureObject;
/*     */ import net.minecraft.client.renderer.texture.TextureManager;
/*     */ import net.minecraft.client.renderer.texture.TextureMap;
/*     */ import net.minecraft.client.renderer.vertex.DefaultVertexFormats;
/*     */ import net.minecraft.client.resources.IResource;
/*     */ import net.minecraft.client.resources.IResourceManager;
/*     */ import net.minecraft.entity.Entity;
/*     */ import net.minecraft.entity.EntityLivingBase;
/*     */ import net.minecraft.entity.player.EntityPlayer;
/*     */ import net.minecraft.util.ResourceLocation;
/*     */ import net.minecraft.util.math.MathHelper;
/*     */ import net.minecraft.util.math.Vec3d;
/*     */ import net.minecraftforge.client.event.RenderLivingEvent;
/*     */ import net.minecraftforge.common.MinecraftForge;
/*     */ import net.minecraftforge.event.entity.EntityJoinWorldEvent;
/*     */ import net.minecraftforge.fml.common.eventhandler.Event;
/*     */ import net.minecraftforge.fml.common.eventhandler.EventPriority;
/*     */ import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
/*     */ import net.minecraftforge.fml.common.network.FMLNetworkEvent;
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ public class tfa
/*     */   extends RenderLivingBase
/*     */ {
/*  57 */   private static final Minecraft w = Minecraft.func_71410_x();
/*     */   public static boolean q = false;
/*     */   private float g;
/*     */   
/*     */   public tfa() {
/*  62 */     super(Minecraft.func_71410_x().func_175598_ae(), null, 1.0F);
/*  63 */     func_177094_a(new ot(this));
/*     */   }
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */   
/*     */   public static void v(int a, int i, float f1, float f2, float f3, float f4, float f5, float f6, float f7, float f8) {
/*  80 */     f7 = 1.0F / f7;
/*  81 */     f8 = 1.0F / f8;
/*  82 */     Tessellator tessellator = Tessellator.func_178181_a();
/*  83 */     BufferBuilder bufferBuilder = tessellator.func_178180_c();
/*  84 */     bufferBuilder.func_181668_a(7, DefaultVertexFormats.field_181707_g);
/*  85 */     bufferBuilder.func_181662_b((a - f5 / 2.0F), (i + f4 - f6 / 2.0F), 0.0D).func_187315_a((f1 * f7), ((f2 + f4) * f8)).func_181675_d();
/*  86 */     bufferBuilder.func_181662_b((a + f3 - f5 / 2.0F), (i + f4 - f6 / 2.0F), 0.0D).func_187315_a(((f1 + f3) * f7), ((f2 + f4) * f8)).func_181675_d();
/*  87 */     bufferBuilder.func_181662_b((a + f3 - f5 / 2.0F), (i - f6 / 2.0F), 0.0D).func_187315_a(((f1 + f3) * f7), (f2 * f8)).func_181675_d();
/*  88 */     bufferBuilder.func_181662_b((a - f5 / 2.0F), (i - f6 / 2.0F), 0.0D).func_187315_a((f1 * f7), (f2 * f8)).func_181675_d();
/*  89 */     tessellator.func_78381_a();
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   @SubscribeEvent
/*     */   public void onjoin(FMLNetworkEvent.ClientDisconnectionFromServerEvent clientDisconnectionFromServerEvent) {}
/*     */ 
/*     */   
/*     */   @SubscribeEvent
/*     */   public void onjoin(EntityJoinWorldEvent entityJoinWorldEvent) {
/* 100 */     if (entityJoinWorldEvent.getEntity() != null && !(entityJoinWorldEvent.getEntity() instanceof net.minecraft.entity.item.EntityItem)) {
/* 101 */       uy.z(entityJoinWorldEvent.getEntity().func_110124_au());
/*     */     }
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   @SubscribeEvent
/*     */   public void onServerFileEvent(EventLoader.ServerFileEvent serverFileEvent) {
/* 109 */     if (serverFileEvent.getFileName().startsWith("PlayerAnimation/")) {
/* 110 */       Map<String, bo> map = bg.v(serverFileEvent.getFileName(), new ByteArrayInputStream(serverFileEvent
/* 111 */             .getBytes()));
/* 112 */       xea.m.w.putAll(map);
/* 113 */       xea.m.q.clear();
/*     */     } 
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   @SubscribeEvent(priority = EventPriority.LOWEST)
/*     */   public void onRenderLivingEvent1(RenderLivingEvent.Pre pre) {
/* 121 */     if (!vda.q) {
/*     */       return;
/*     */     }
/*     */     
/* 125 */     if (!(pre.getEntity() instanceof EntityOtherPlayerMP))
/* 126 */       return;  EntityOtherPlayerMP entityOtherPlayerMP = (EntityOtherPlayerMP)pre.getEntity();
/* 127 */     if (entityOtherPlayerMP.func_70005_c_().contains("§"))
/*     */       return; 
/* 129 */     drawEntityHealthBar((EntityLivingBase)entityOtherPlayerMP, "player", pre.getX(), pre.getY(), pre.getZ());
/*     */   }
/*     */   
/*     */   @SubscribeEvent
/*     */   public void onRenderLivingEventSpecialsPre(RenderLivingEvent.Specials.Pre pre) {
/* 134 */     if (!vda.q) {
/*     */       return;
/*     */     }
/* 137 */     if (pre.getEntity() == null)
/* 138 */       return;  xea.eos/moe/dragoncore/ija eos/moe/dragoncore/ija = xea.m.v(pre.getEntity());
/* 139 */     if (eos/moe/dragoncore/ija == null)
/* 140 */       return;  if (eos/moe/dragoncore/ija.t() && eos/moe/dragoncore/ija.s()) {
/* 141 */       pre.setCanceled(true);
/*     */     }
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   @SubscribeEvent(priority = EventPriority.LOWEST)
/*     */   public void onRenderLivingEvent(RenderLivingEvent.Pre pre) {
/* 149 */     if (!vda.q) {
/*     */       return;
/*     */     }
/* 152 */     if (!(pre.getEntity() instanceof EntityLivingBase))
/*     */       return; 
/* 154 */     if (pre.isCanceled()) {
/*     */       return;
/*     */     }
/* 157 */     xea.eos/moe/dragoncore/ija eos/moe/dragoncore/ija = xea.m.v(pre.getEntity());
/* 158 */     if (eos/moe/dragoncore/ija == null)
/* 159 */       return;  double d1 = pre.getX();
/* 160 */     double d2 = pre.getY();
/* 161 */     if (pre.getEntity() instanceof EntityPlayer && pre.getEntity().func_70093_af()) {
/* 162 */       d2 += 0.125D;
/*     */     }
/* 164 */     this.g = 90.0F;
/*     */ 
/*     */     
/* 167 */     double d3 = pre.getZ();
/* 168 */     if (!eos/moe/dragoncore/ija.t() && !q) {
/* 169 */       xea.eos/moe/dragoncore/tga eos/moe/dragoncore/tga = eos/moe/dragoncore/ija.v();
/* 170 */       if (eos/moe/dragoncore/tga == null)
/*     */         return; 
/* 172 */       ModelBase modelBase = eos/moe/dragoncore/tga.v();
/* 173 */       if (modelBase == null)
/*     */         return; 
/* 175 */       pre.setCanceled(true);
/*     */       
/* 177 */       EntityLivingBase entityLivingBase = pre.getEntity();
/*     */       
/* 179 */       entityLivingBase.field_70131_O = eos/moe/dragoncore/ija.z();
/* 180 */       entityLivingBase.field_70130_N = eos/moe/dragoncore/ija.v();
/*     */       
/* 182 */       zz zz = null;
/* 183 */       AnimationEntityModel animationEntityModel = null;
/* 184 */       if (!eos/moe/dragoncore/ija.v() && !eos/moe/dragoncore/ija.y()) {
/* 185 */         kq.q.init(entityLivingBase, true);
/* 186 */         zz = kq.q.getEntityManager(entityLivingBase.func_110124_au());
/* 187 */         if (zz != null && modelBase instanceof AnimationEntityModel)
/*     */         {
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */           
/* 200 */           animationEntityModel = (AnimationEntityModel)modelBase;
/* 201 */           xea.l.v();
/* 202 */           v((Entity)entityLivingBase, animationEntityModel, zz);
/*     */         }
/*     */       
/* 205 */       } else if (eos/moe/dragoncore/ija.v() && modelBase instanceof iy) {
/* 206 */         iy iy = (iy)modelBase;
/* 207 */         float f1 = 0.0F;
/* 208 */         float f2 = 0.0F;
/* 209 */         if (entityLivingBase.func_70089_S()) {
/* 210 */           f1 = Interpolations.lerp(entityLivingBase.field_184618_aE, entityLivingBase.field_70721_aZ, pre.getPartialRenderTick());
/* 211 */           f2 = entityLivingBase.field_184619_aG - entityLivingBase.field_70721_aZ * (1.0F - pre.getPartialRenderTick());
/* 212 */           if (entityLivingBase.func_70631_g_()) {
/* 213 */             f2 *= 3.0F;
/*     */           }
/*     */           
/* 216 */           if (f1 > 1.0F) {
/* 217 */             f1 = 1.0F;
/*     */           }
/* 219 */           boolean bool1 = (f1 <= -0.15F || f1 >= 0.15F);
/* 220 */           if (bool1) {
/* 221 */             iy.setAnimation("walk");
/*     */           } else {
/* 223 */             iy.setAnimation("idle");
/*     */           } 
/*     */         } 
/*     */       } 
/*     */ 
/*     */       
/* 229 */       float f = pre.getPartialRenderTick();
/*     */ 
/*     */       
/* 232 */       GlStateManager.func_179094_E();
/* 233 */       GlStateManager.func_179129_p();
/*     */ 
/*     */       
/* 236 */       this.field_77045_g = modelBase;
/* 237 */       this.field_77045_g.field_78095_p = func_77040_d(entityLivingBase, f);
/* 238 */       boolean bool = (entityLivingBase.func_184218_aH() && entityLivingBase.func_184187_bx() != null && entityLivingBase.func_184187_bx().shouldRiderSit());
/* 239 */       this.field_77045_g.field_78093_q = bool;
/* 240 */       this.field_77045_g.field_78091_s = entityLivingBase.func_70631_g_();
/*     */ 
/*     */       
/* 243 */       ResourceLocation resourceLocation = eos/moe/dragoncore/ija.t();
/* 244 */       if (resourceLocation.func_110624_b().equals("dragoncore")) {
/* 245 */         func_110776_a(resourceLocation);
/*     */       }
/*     */ 
/*     */       
/*     */       try {
/* 250 */         float f1 = func_77034_a(entityLivingBase.field_70760_ar, entityLivingBase.field_70761_aq, f);
/* 251 */         float f2 = func_77034_a(entityLivingBase.field_70758_at, entityLivingBase.field_70759_as, f);
/* 252 */         float f3 = f2 - f1;
/*     */         
/* 254 */         if (bool && entityLivingBase.func_184187_bx() instanceof EntityLivingBase) {
/* 255 */           EntityLivingBase entityLivingBase1 = (EntityLivingBase)entityLivingBase.func_184187_bx();
/* 256 */           f1 = func_77034_a(entityLivingBase1.field_70760_ar, entityLivingBase1.field_70761_aq, f);
/* 257 */           f3 = f2 - f1;
/* 258 */           float f9 = MathHelper.func_76142_g(f3);
/*     */           
/* 260 */           if (f9 < -85.0F) {
/* 261 */             f9 = -85.0F;
/*     */           }
/*     */           
/* 264 */           if (f9 >= 85.0F) {
/* 265 */             f9 = 85.0F;
/*     */           }
/*     */           
/* 268 */           f1 = f2 - f9;
/*     */           
/* 270 */           if (f9 * f9 > 2500.0F) {
/* 271 */             f1 += f9 * 0.2F;
/*     */           }
/*     */           
/* 274 */           f3 = f2 - f1;
/*     */         } 
/*     */         
/* 277 */         float f4 = entityLivingBase.field_70127_C + (entityLivingBase.field_70125_A - entityLivingBase.field_70127_C) * f;
/* 278 */         eb eb = xea.l;
/*     */ 
/*     */         
/* 281 */         eb.v("query.yaw", f3);
/* 282 */         if (entityLivingBase.func_184599_cB() > 4) {
/* 283 */           eb.v("query.pitch", -45.0D);
/*     */         } else {
/* 285 */           eb.v("query.pitch", f4);
/*     */         } 
/* 287 */         if (zz != null && animationEntityModel != null) {
/* 288 */           zz.v(animationEntityModel);
/*     */ 
/*     */ 
/*     */           
/* 292 */           if (zz.i != null) {
/* 293 */             for (Map.Entry<String, Boolean> entry : zz.i.entrySet()) {
/* 294 */               AnimationModelRenderer animationModelRenderer = animationEntityModel.getBaseModel().getPiece((String)entry.getKey());
/* 295 */               if (animationModelRenderer != null && animationModelRenderer instanceof ModelRenderer) {
/* 296 */                 ((ModelRenderer)animationModelRenderer).field_78806_j = ((Boolean)entry.getValue()).booleanValue();
/*     */               }
/*     */             } 
/*     */           }
/*     */         } 
/*     */ 
/*     */         
/* 303 */         func_77039_a(entityLivingBase, d1, d2, d3);
/* 304 */         float f5 = func_77044_a(entityLivingBase, f);
/*     */         
/* 306 */         if (!eos/moe/dragoncore/ija.y() && eos/moe/dragoncore/ija.h() != 0.0F) {
/* 307 */           GlStateManager.func_179152_a(eos/moe/dragoncore/ija.h(), eos/moe/dragoncore/ija.h(), eos/moe/dragoncore/ija.h());
/*     */         }
/* 309 */         func_77043_a(entityLivingBase, f5, f1, f);
/* 310 */         float f6 = func_188322_c(entityLivingBase, f);
/* 311 */         float f7 = 0.0F;
/* 312 */         float f8 = 0.0F;
/*     */         
/* 314 */         if (!entityLivingBase.func_184218_aH()) {
/* 315 */           f7 = entityLivingBase.field_184618_aE + (entityLivingBase.field_70721_aZ - entityLivingBase.field_184618_aE) * f;
/* 316 */           f8 = entityLivingBase.field_184619_aG - entityLivingBase.field_70721_aZ * (1.0F - f);
/*     */           
/* 318 */           if (entityLivingBase.func_70631_g_()) {
/* 319 */             f8 *= 3.0F;
/*     */           }
/*     */           
/* 322 */           if (f7 > 1.0F) {
/* 323 */             f7 = 1.0F;
/*     */           }
/* 325 */           f3 = f2 - f1;
/*     */         } 
/*     */         
/* 328 */         GlStateManager.func_179141_d();
/* 329 */         this.field_77045_g.func_78086_a(entityLivingBase, f8, f7, f);
/*     */ 
/*     */ 
/*     */ 
/*     */         
/* 334 */         if (this.field_188301_f) {
/*     */           
/* 336 */           boolean bool1 = func_177088_c(entityLivingBase);
/* 337 */           GlStateManager.func_179142_g();
/* 338 */           GlStateManager.func_187431_e(func_188298_c((Entity)entityLivingBase));
/*     */           
/* 340 */           if (!this.field_188323_j) {
/* 341 */             func_77036_a(entityLivingBase, f8, f7, f5, f3, f4, f6);
/*     */           }
/*     */ 
/*     */           
/* 345 */           func_177093_a(entityLivingBase, f8, f7, f, f5, f3, f4, f6);
/*     */           
/* 347 */           if (!(entityLivingBase instanceof EntityPlayer) || !((EntityPlayer)entityLivingBase).func_175149_v()) {
/* 348 */             func_177093_a(entityLivingBase, f8, f7, f, f5, f3, f4, f6);
/*     */           }
/*     */           
/* 351 */           GlStateManager.func_187417_n();
/* 352 */           GlStateManager.func_179119_h();
/*     */           
/* 354 */           if (bool1) {
/* 355 */             func_180565_e();
/*     */           }
/*     */         } else {
/* 358 */           boolean bool1 = setDoRenderBrightness(entityLivingBase, f, eos/moe/dragoncore/ija.d());
/*     */ 
/*     */           
/* 361 */           GlStateManager.func_179094_E();
/* 362 */           eos/moe/dragoncore/ija.v();
/* 363 */           func_77036_a(entityLivingBase, f8, f7, f5, f3, f4, f6);
/* 364 */           GlStateManager.func_179121_F();
/* 365 */           if (bool1) {
/* 366 */             func_177091_f();
/*     */           }
/*     */           
/* 369 */           GlStateManager.func_179132_a(true);
/*     */           
/* 371 */           if (!(entityLivingBase instanceof EntityPlayer) || !((EntityPlayer)entityLivingBase).func_175149_v()) {
/* 372 */             func_177093_a(entityLivingBase, f8, f7, f, f5, f3, f4, f6);
/*     */           }
/*     */         } 
/*     */ 
/*     */         
/* 377 */         GlStateManager.func_179101_C();
/* 378 */       } catch (Exception exception) {
/* 379 */         exception.printStackTrace();
/*     */       } 
/* 381 */       if (this.field_77045_g instanceof rm) {
/* 382 */         ((rm)this.field_77045_g).clearData();
/*     */       }
/* 384 */       GlStateManager.func_179138_g(OpenGlHelper.field_77476_b);
/* 385 */       GlStateManager.func_179098_w();
/* 386 */       GlStateManager.func_179138_g(OpenGlHelper.field_77478_a);
/* 387 */       GlStateManager.func_179089_o();
/* 388 */       GlStateManager.func_179121_F();
/*     */       
/* 390 */       drawEntityHealthBar(entityLivingBase, eos/moe/dragoncore/ija.v(), d1, d2, d3);
/* 391 */       if (!this.field_188301_f && !eos/moe/dragoncore/ija.s()) {
/* 392 */         pre.getRenderer().func_177067_a(entityLivingBase, d1, d2, d3);
/*     */       }
/*     */       
/* 395 */       MinecraftForge.EVENT_BUS.post((Event)new RenderLivingEvent.Post(entityLivingBase, pre.getRenderer(), f, d1, d2, d3));
/*     */     } else {
/* 397 */       drawEntityHealthBar(pre.getEntity(), eos/moe/dragoncore/ija.v(), d1, d2, d3);
/*     */     } 
/*     */   }
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */   
/*     */   public void func_77036_a(EntityLivingBase entityLivingBase, float f1, float f2, float f3, float f4, float f5, float f6) {
/* 407 */     if (entityLivingBase.field_70128_L) {
/*     */       return;
/*     */     }
/* 410 */     boolean bool1 = func_193115_c(entityLivingBase);
/* 411 */     boolean bool2 = (!bool1 && !entityLivingBase.func_98034_c((EntityPlayer)(Minecraft.func_71410_x()).field_71439_g));
/* 412 */     if (bool1 || bool2) {
/* 413 */       xea.eos/moe/dragoncore/ija eos/moe/dragoncore/ija = xea.m.v(entityLivingBase);
/*     */ 
/*     */       
/* 416 */       func_110776_a(eos/moe/dragoncore/ija.t());
/*     */       
/* 418 */       if (bool2) {
/* 419 */         GlStateManager.func_187408_a(GlStateManager.Profile.TRANSPARENT_MODEL);
/*     */       }
/*     */ 
/*     */       
/* 423 */       this.field_77045_g.func_78088_a((Entity)entityLivingBase, f1, f2, f3, f4, f5, f6);
/*     */ 
/*     */ 
/*     */       
/* 427 */       if (eos/moe/dragoncore/ija.v() != null) {
/*     */         
/* 429 */         ResourceLocation resourceLocation = eos/moe/dragoncore/ija.v();
/* 430 */         if (resourceLocation.func_110624_b().equals("dragoncore")) {
/* 431 */           func_110776_a(resourceLocation);
/*     */         }
/*     */         
/* 434 */         float f7 = OpenGlHelper.lastBrightnessX;
/* 435 */         float f8 = OpenGlHelper.lastBrightnessY;
/*     */         
/* 437 */         OpenGlHelper.func_77475_a(OpenGlHelper.field_77476_b, 240.0F, f8);
/* 438 */         this.field_77045_g.func_78088_a((Entity)entityLivingBase, f1, f2, f3, f4, f5, f6);
/* 439 */         OpenGlHelper.func_77475_a(OpenGlHelper.field_77476_b, f7, f8);
/*     */       } 
/*     */       
/* 442 */       if (bool2) {
/* 443 */         GlStateManager.func_187440_b(GlStateManager.Profile.TRANSPARENT_MODEL);
/*     */       }
/*     */     } 
/*     */   }
/*     */ 
/*     */   
/*     */   public void func_110776_a(ResourceLocation resourceLocation) {
/* 450 */     if (!v(resourceLocation))
/*     */     {
/*     */       
/* 453 */       super.func_110776_a(resourceLocation);
/*     */     }
/*     */   }
/*     */ 
/*     */   
/*     */   public static boolean v(ResourceLocation a) {
/* 459 */     if (a.func_110624_b().equals("dragoncore")) {
/* 460 */       IResourceManager iResourceManager = Minecraft.func_71410_x().func_110442_L();
/* 461 */       TextureManager textureManager = Minecraft.func_71410_x().func_110434_K();
/*     */ 
/*     */       
/* 464 */       if (textureManager.func_110581_b(a) == null)
/*     */       {
/*     */         
/* 467 */         try (IResource a = iResourceManager.func_110536_a(a)) {
/* 468 */           if (iResource.func_110528_c()) {
/* 469 */             wp wp = new wp("");
/* 470 */             wp.func_174943_a(iResourceManager, textureMap -> textureMap.func_174942_a(a));
/*     */ 
/*     */ 
/*     */ 
/*     */             
/* 475 */             textureManager.func_110580_a(a, (ITickableTextureObject)wp);
/*     */           }
/*     */         
/* 478 */         } catch (IOException iOException) {}
/*     */       }
/*     */ 
/*     */       
/* 482 */       textureManager.func_110577_a(a);
/* 483 */       return true;
/*     */     } 
/* 485 */     return false;
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   public void drawEntityHealthBar(EntityLivingBase entityLivingBase, String str, double d1, double d2, double d3) {
/* 491 */     if (str == null || !kba.q.v().containsKey(str))
/*     */       return; 
/* 493 */     kba.eos/moe/dragoncore/dfa eos/moe/dragoncore/dfa = kba.q.v().get(str);
/*     */     
/* 495 */     float f1 = this.field_76990_c.field_78735_i;
/* 496 */     float f2 = this.field_76990_c.field_78732_j;
/* 497 */     boolean bool = (this.field_76990_c.field_78733_k.field_74320_O == 2);
/*     */ 
/*     */     
/* 500 */     GlStateManager.func_179094_E();
/* 501 */     GlStateManager.func_179137_b(d1, d2 + eos/moe/dragoncore/dfa.v(entityLivingBase), d3);
/* 502 */     GlStateManager.func_187432_a(0.0F, 1.0F, 0.0F);
/* 503 */     GlStateManager.func_179114_b(-f1, 0.0F, 1.0F, 0.0F);
/* 504 */     GlStateManager.func_179114_b((bool ? -1 : true) * f2, 1.0F, 0.0F, 0.0F);
/* 505 */     GlStateManager.func_179152_a(-0.025F, -0.025F, 0.025F);
/* 506 */     GlStateManager.func_179140_f();
/*     */     
/* 508 */     GlStateManager.func_179147_l();
/* 509 */     GlStateManager.func_187428_a(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA, GlStateManager.SourceFactor.ONE, GlStateManager.DestFactor.ZERO);
/*     */ 
/*     */ 
/*     */ 
/*     */     
/* 514 */     GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
/* 515 */     hw.v(eos/moe/dragoncore/dfa.z());
/* 516 */     float f3 = eos/moe/dragoncore/dfa.t(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/* 517 */     float f4 = eos/moe/dragoncore/dfa.h(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/* 518 */     v(0, 0, 0.0F, 0.0F, f3, f4, f3, f4);
/*     */     
/* 520 */     GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
/* 521 */     hw.v(eos/moe/dragoncore/dfa.v());
/*     */ 
/*     */     
/* 524 */     GlStateManager.func_179109_b(0.0F, 0.0F, -0.1F);
/* 525 */     GlStateManager.func_179139_a(1.01D, 1.01D, 1.01D);
/* 526 */     float f5 = eos/moe/dragoncore/dfa.z(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/*     */     
/* 528 */     float f6 = eos/moe/dragoncore/dfa.v(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/*     */     
/* 530 */     v(0, 0, 0.0F, 0.0F, f5, f6, f3, f4, f3, f4);
/*     */ 
/*     */     
/* 533 */     GlStateManager.func_179109_b(-f3 / 2.0F, -f4 / 2.0F, -0.1F);
/* 534 */     for (kba.eos/moe/dragoncore/fia eos/moe/dragoncore/fia : eos/moe/dragoncore/dfa.v()) {
/* 535 */       GlStateManager.func_179094_E();
/* 536 */       GlStateManager.func_179152_a(eos/moe/dragoncore/fia.v(), eos/moe/dragoncore/fia.v(), eos/moe/dragoncore/fia.v());
/* 537 */       String str1 = eos/moe/dragoncore/fia.v(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP(), entityLivingBase.func_145748_c_().func_150254_d());
/* 538 */       float f7 = eos/moe/dragoncore/fia.z(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/* 539 */       float f8 = eos/moe/dragoncore/fia.v(entityLivingBase.func_110143_aJ(), entityLivingBase.func_110138_aP());
/* 540 */       if (eos/moe/dragoncore/fia.v()) {
/* 541 */         f7 -= w.field_71466_p.func_78256_a(str1) * eos/moe/dragoncore/fia.v() / 2.0F;
/*     */       }
/*     */       
/* 544 */       w.field_71466_p.func_175065_a(str1, f7, f8, -16777216, false);
/* 545 */       GlStateManager.func_179121_F();
/*     */     } 
/*     */ 
/*     */ 
/*     */     
/* 550 */     GlStateManager.func_179145_e();
/* 551 */     GlStateManager.func_179084_k();
/* 552 */     GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
/* 553 */     GlStateManager.func_179121_F();
/*     */   }
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */   
/*     */   public ResourceLocation func_110775_a(Entity entity) {
/* 617 */     xea.eos/moe/dragoncore/ija eos/moe/dragoncore/ija = xea.m.v((EntityLivingBase)entity);
/* 618 */     if (eos/moe/dragoncore/ija == null) return new ResourceLocation("dragoncore", "empty.png");
/*     */ 
/*     */     
/* 621 */     return eos/moe/dragoncore/ija.t();
/*     */   }
/*     */ 
/*     */ 
/*     */   
/*     */   public float func_188322_c(EntityLivingBase entityLivingBase, float f) {
/* 627 */     xea.eos/moe/dragoncore/ija eos/moe/dragoncore/ija = xea.m.v(entityLivingBase);
/* 628 */     if (eos/moe/dragoncore/ija != null && eos/moe/dragoncore/ija.y()) {
/* 629 */       GlStateManager.func_179091_B();
/*     */       
/* 631 */       GlStateManager.func_179152_a(eos/moe/dragoncore/ija.h(), eos/moe/dragoncore/ija.h(), eos/moe/dragoncore/ija.h());
/* 632 */       GlStateManager.func_179114_b(180.0F, 0.0F, (float)entityLivingBase.field_70163_u, 0.0F);
/* 633 */       func_77041_b(entityLivingBase, f);
/* 634 */       return 0.0625F;
/*     */     } 
/* 636 */     return super.func_188322_c(entityLivingBase, f);
/*     */   }
/*     */ 
/*     */   
/*     */   public boolean setDoRenderBrightness(EntityLivingBase entityLivingBase, float f, boolean bool) {
/* 641 */     int i = entityLivingBase.field_70725_aQ;
/* 642 */     int j = entityLivingBase.field_70737_aN;
/* 643 */     if (!bool) {
/* 644 */       entityLivingBase.field_70725_aQ = 0;
/* 645 */       entityLivingBase.field_70737_aN = 0;
/*     */     } 
/* 647 */     boolean bool1 = func_177092_a(entityLivingBase, f, true);
/* 648 */     if (!bool) {
/* 649 */       entityLivingBase.field_70725_aQ = i;
/* 650 */       entityLivingBase.field_70737_aN = j;
/*     */     } 
/* 652 */     return bool1;
/*     */   }
/*     */ }


/* Location:              D:\fanbian\[D][龙之核心]DragonCore-2.6.0.3.jar!\eos\moe\dragoncore\tfa.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */